package com.alibaba.citrus.cr.mn.order.center.facade.repository;

import com.alibaba.citrus.cr.mn.order.center.facade.function.dataobject.AtomOrderDO;
import com.epoch.app.mnordercenter.model.dto.SalesOrderAtomCreateResponse;

/**
 * @author zhangxiaorui
 * @ClassName AtomOrderRepository
 * @description: TODO
 * @date 2023/04/25 20:07
 * @version: 1.0
 */
public interface AtomOrderRepository {

    /**
     * 保存销售订单+明细数据
     * @param atomOrder 订单+明细模型
     * @return <保存结果, 主单ID, 子单ID>
     */
    SalesOrderAtomCreateResponse saveOrder(AtomOrderDO atomOrder);

    /**
     * 保存销售订单+明细数据
     * @param atomOrder 订单+明细模型
     * @param response <保存结果, 主单ID, 子单ID>
     * @return
     */
    void saveOrder2(AtomOrderDO atomOrder, SalesOrderAtomCreateResponse response);

    /**
     * 更新销售订单
     * @param atomOrder
     */
    void updateOrderStatus(AtomOrderDO atomOrder);

}
